<template>
  <div class="monitoring">
    <el-form ref="form" :model="form" label-width="95px">
      <el-form-item label="人员姓名" style="width: 250px;">
        <el-input v-model="form.name" placeholder="请输入"></el-input>
      </el-form-item>
      <!-- <el-form-item label="车辆类型" label-width="70px" style="width: 220px;">
        <el-select v-model="form.carTypeValue" placeholder="请选择车辆类型">
          <el-option
            v-for="(item,index) in selectCarType"
            :value="item.label"
            :label="item.value"
            :key="index"
          ></el-option>
        </el-select>
      </el-form-item>-->
      <el-form-item label="分组" style="width: 230px;">
        <el-select v-model="form.groupingValue" :options="groupingList" placeholder="请选择分组">
          <el-option
            v-for="(item,index) in groupingList"
            :value="item.CLIENT_NO"
            :label="item.CLIENT_NAME"
            :key="index"
          ></el-option>
        </el-select>
      </el-form-item>
      <el-form-item label="状态" style="width: 170px;">
        <!-- <el-cascader v-model="form.groupingValue" :options="groupingList" style="line-height: 26px;"></el-cascader> -->
        <el-select v-model="form.statusValue" :options="statusOptions" placeholder="请选择状态">
          <el-option
            v-for="(item,index) in statusOptions"
            :value="item.value"
            :label="item.label"
            :key="index"
          ></el-option>
        </el-select>
      </el-form-item>
      <span style="margin-left: 15px;font-size: small;">人员数量：{{this.carNum}}人</span>
      <!-- <el-form-item label="排序"> -->
      <!-- <el-radio-group
        v-model="radio"
        size="mini"
        fill="#007ACC"
        text-color="#fff"
        style="padding-left:12px;padding-right:8px;"
        @change="getInfoList"
      >
        <el-radio-button label="定位时间"></el-radio-button>
        <el-radio-button label="称重时间"></el-radio-button>
      </el-radio-group>-->
      <!-- </el-form-item> -->
      <!-- <div style="float: right;padding-right:30px;">
        <div class="people_number">
          在线:
          <span>{{statusNums.onlines}}</span>人
        </div>
        <div class="people_number">
          全部:
          <span>{{statusNums.alls}}</span>人
        </div>
      </div> -->

      <el-button size="mini" type="primary" @click="screenData" style="margin-left:15px;">查 询</el-button>
      <!-- <el-form-item label="尾迹" style="width: 110px; margin-right: 10px">
        <el-select v-model="wakeValue" placeholder="尾迹">
          <el-option value="显示"></el-option>
          <el-option value="隐藏"></el-option>
        </el-select>
      </el-form-item>-->
      <!-- <div class="buttons"> -->
      <!-- <el-button
          class="iconfont icon-kaishi iconone"
          type="success"
          style="background-color:#347F10; color: #fff;"
          @click="startTracking"
          :disabled="disabled1"
        >开始跟踪</el-button>
        <el-button
          class="iconfont icon-tingzhi iconone"
          type="danger"
          style="background-color:#B36969; color: #fff; border: 0 none;"
          @click="cancelTracking"
          :disabled="disabled2"
      >取消跟踪</el-button>-->
      <!-- <el-button
        class="iconfont icon-tongji iconone"
        type="primary"
        size="mini"
        style="background:#468AD0"
        @click="onlineStatistics"
      >实时在线统计</el-button>-->
      <!-- <el-button
        class="iconfont icon-daochu iconone"
        size="mini"
        style="background-color: green; color: #fff; border: 0 none;"
        @click="exportExcel"
      >导出基础信息表</el-button>-->
      <el-button
        class="iconfont icon-daochu iconone"
        size="mini"
        style="background-color: green; color: #fff; border: 0 none;"
        @click="exportExcel"
      >导出实时信息表</el-button>
      <!-- 自动刷新 -->
      <!-- <div class="switch iconone">
        <span>自动刷新</span>
        <el-switch
          v-model="switch_value"
          active-color="#13ce66"
          inactive-color="#ccc"
          @change="selectChange"
        ></el-switch>
      </div>-->
    </el-form>
    <!-- 人员信息列表 -->
    <div class="table_list">
      <el-table
        :data="screeningData"

        height="100%"
        style="width: 100%"
        size="mini"
        border
        fit
        highlight-current-row
        @row-contextmenu="rowHandle"
        @row-click="clickRow"
        @row-dblclick="dblClickRow"
        @cell-mouse-enter="cellMouseEnter"
      >
        <el-table-column prop="VID" label="编号" width="80"></el-table-column>
        <el-table-column prop="CLIENT_NAME" label="组织名称" width="200"></el-table-column>
        <el-table-column prop="NAME" label="名称" width="110"></el-table-column>
        <el-table-column prop="PHONE" label="电话" width="180"></el-table-column>
        <el-table-column prop="WORKTYPE" label="类型" sortable width="180"></el-table-column>
        <el-table-column prop="STATUSstr" label="状态" width="110"></el-table-column>
        <el-table-column prop="FORWORK" label="负责维保公厕" width="180"></el-table-column>
        <el-table-column prop="INWORK" label="正在维保公厕" width="220"></el-table-column>
        <el-table-column prop="GPSTIME" label="最终定位时间" sortable width="180"></el-table-column>
        <el-table-column prop="LNG" label="经度" width="100"></el-table-column>
        <el-table-column prop="LAT" label="纬度" width="90"></el-table-column>
      </el-table>
    </div>
    <!-- 右键人员列表菜单 -->
    <div
      class="row_box"
      v-if="MouseEvent.isShow"
      :style="`left: ${MouseEvent.left}px; top: ${MouseEvent.top}px;`"
    >
      <!-- <span @click="exportRowExcel">导出Excel</span> -->
      <!-- <span @click="groupArea(teamNumber)">负责区域</span> -->
      <!-- <span @click="clearArea(teamNumber)">清扫队负责区域</span> -->
      <!-- <span>负责区域</span> -->
      <!-- <span @click="cleanArea">清除区域</span> -->
      <span @click="trajectory">轨迹回放</span>
      <!-- <span @click="showCCTV">视频监控</span> -->
    </div>
    <!-- 实时在线统计 -->
    <div class="statistical" v-if="Visible">
      <div class="title">
        <i class="iconfont icon-tongji1" />
        <h3>实时在线统计</h3>
        <span class="iconfont icon-guanbi close" @click="close" />
      </div>
      <div class="statistical_content">
        <el-table :data="statisticalData" style="width: 100%"  border>
          <!-- <el-table-column prop="名称" label="区域" align="center"></el-table-column> -->
          <el-table-column prop="AreaName" label="区域" align="center"></el-table-column>
          <el-table-column prop="OnlineVehicle" label="在线车辆(作业)" align="center"></el-table-column>
          <el-table-column prop="AllVehicle" label="全部车辆" align="center"></el-table-column>
        </el-table>
      </div>
      <div
        class="statistical_time"
      >统计时间：{{new Date().toLocaleDateString() + ' - ' + new Date().toTimeString().split(' ')[0]}}</div>
    </div>
    <el-dialog
      :title="dialogVisibleCCTVTitle"
      :visible.sync="dialogVisibleCCTV"
      width="720px"
      height="50%"
    >
      <iframe id="dialogVisibleCCTViframe" src frameborder="0" width="100%" height="500px"></iframe>
      <span slot="footer" class="dialog-footer">
        <el-button @click="dialogVisibleCCTV = false">取 消</el-button>
        <el-button type="primary" @click="dialogVisibleCCTV = false">确 定</el-button>
      </span>
    </el-dialog>
  </div>
</template>

<script>
import eventBus from '@/eventBus.js'

import export2Excel from '@/utils/exportExcel/index.js'
// 转换地图坐标
// import { getLatLng } from '@/assets/js/pointtransfertools.js'

// import { BMap } from 'vue-baidu-map'
// import BaiduMap from 'vue-baidu-map/components/map/Map.vue'

export default {
  data () {
    return {
      timeID: '',
      dialogVisibleCCTVTitle: "",
      dialogVisibleCCTV: false,
      account: '',
      // 筛选条件
      form: {
        name: '',
        groupingValue: '',
        statusValue: 1,
        carTypeValue: '全部'
      },
      // 垃圾桶点位数据
      boxData: [],
      // 原始数据
      originalData: [],
      // 类型列表
      typeOptions: ['全部', '巡查员', '指导员'],
      // 状态列表
      statusOptions: [
        { value: '全部', label: '全部' },
        { value: 1, label: '在线' },
        { value: 0, label: '离线' }
      ],
      // tableData: [],
      statusNums: {
        alls: 0,
        onlines: 0,
        outlines: 0
      },
      // person_data: [],
      switch_value: true,
      time_value: '',
      time_Interval: [{
        value: 10000,
        label: '10秒'
      }, {
        value: 30000,
        label: '30秒'
      }, {
        value: 60000,
        label: '1分钟'
      }],
      groupingList: [],
      selectCarType: [{
        value: '全部',
        label: '全部'
      }, {
        value: '机扫车',
        label: '机扫车'
      }, {
        value: '小型机扫车',
        label: '小型机扫车'
      }, {
        value: '吸尘车',
        label: '吸尘车'
      }, {
        value: '洒水车',
        label: '洒水车'
      }, {
        value: '高压清洗车',
        label: '高压清洗车'
      }, {
        value: '洗路车',
        label: '洗路车'
      }, {
        value: '除雪车',
        label: '除雪车'
      }],
      wakeValue: '',
      // 筛选数据
      screeningData: [],
      //查询出来的车辆数
      carNum:0,
      // 是否显示实时在线统计对话框
      Visible: false,
      statisticalData: [],
      MouseEvent: {
        top: 0,
        left: 0,
        isShow: false
      },
      // teamNumber: '',
      // 右键表格
      row: null,
      clickRowData: null,
      disabled1: false,
      disabled2: true,
      trackingValue: false,
      localtion: {},
      radio: '定位时间'
    }
  },
  mounted () {
    this.getInfoList()
    this.selectChange()
    // this.getCLCPolygon()
    this.getGroupingList()
  },
  methods: {
    // 获取人员信息列表
    async getInfoList () {
      var url = 'WC/GetListCurrentToiletWorker?CLIENTNO=' + localStorage.getItem('CLIENT_NO')
      let { data } = await this.$Http.get(url)
      this.statusNums.alls = data.length
      this.statusNums.onlines = data[0].CURRENTNUM
      // // this.statusNums.outlines = data[0].ALLSUM - data[0].CURRENTNUM
      // data.forEach(item => {
        // if (item.STATUS === 0) {
        //   item.STATUSstr = "离线"
        // } else {
        //   item.STATUSstr = "在线"
        // }
      //   //   if (item.VIDEO === '0') {
      //   //     item.VIDEO = ""
      //   //   }else{
      //   //     item.VIDEO = "支持视频监控"
      //   //   }
      //   //   if (item.IsSetupOil === '0') {
      //   //     item.IsSetupOil = ""
      //   //   }else{
      //   //     item.IsSetupOil = "支持油耗"
      //   //   }
      //   //   if (item.LOCKSTATUS === '0') {
      //   //     item.LOCKSTATUS = ""
      //   //   }else{
      //   //     item.LOCKSTATUS = "支持开关量"
      //   //   }
      //   item.GPSTIME = item.GPSTIME.split('.')[0].replace('T', ' ')
      // })
      this.originalData = data.sort((a, b) => {
        let aTimeString = a.GPSTIME
        let bTimeString = b.GPSTIME
        aTimeString = aTimeString.replace(/-/g, '/')
        bTimeString = bTimeString.replace(/-/g, '/')
        const aTime = new Date(aTimeString).getTime()
        const bTime = new Date(bTimeString).getTime()
        return bTime - aTime
      })
      this.screenData()
    },
    // 筛选数据
    screenData () {
      let { name, groupingValue, statusValue, carTypeValue } = this.form
      // if (statusValue === '在线') statusValue = '0'
      // if (statusValue === '离线') statusValue = '6'
      // if (name) {
      //   this.screeningData = this.originalData.filter(item => item.NAME.includes(name))
      // } else {
      //   this.screeningData = this.originalData
      // }
      // this.screeningData = this.screeningData.filter(item => item.CLIENT_NO.includes(groupingValue))
      // if (statusValue !== '全部') this.screeningData = this.screeningData.filter(item => item.STATUS === statusValue)
this.screeningData = [];
      var listTWorker = [];
      var listTWorker_Offline = [];
      this.originalData.forEach(item => {
        if (!item.NAME.includes(name)) {
          return;
        }
        if (!item.CLIENT_NO.includes(groupingValue)) {
          return;
        }
        if (statusValue !== '全部' && item.STATUS != statusValue) {
          return;
        }
        if (item.STATUS === 0) {
          item.STATUSstr = "离线"
          item.img = 'liudongUnline'
          listTWorker.push(item);
        } else {
          item.STATUSstr = "在线"
          item.img = 'liudong'
          listTWorker_Offline.push(item);
        }
        
          this.screeningData.push(item);
      });
      this.carNum = this.screeningData.length
      eventBus.$emit('mapData_ToiletWorker', [listTWorker,listTWorker_Offline])
      eventBus.$emit('mapData_ToiletWorker_count', this.screeningData.length)
    },
    // 获得分组列表
    async getGroupingList () {
      var url = 'WC/GetGroupList?ClientNo=' + localStorage.getItem('CLIENT_NO') // zxdata
      let { data } = await this.$Http.get(url)
      for (var i = data.length - 1; i >= 0; i--) {
        if (data[i].CLIENT_NAME.includes('清运队')) {
          data.splice(i, 1);
        }
      }
      this.groupingList = data
    },
    // 自动查询
    selectChange () {
      // let timeId = null
      if (this.switch_value) {
        var that = this
        this.timeID = setInterval(() => {
          that.getInfoList()
          if (!that.switch_value) clearInterval(that.timeID)
        }, 120000)
      }
    },
    
    // 实时在线统计
    // async onlineStatistics () {
    //   this.Visible = true
    //   // var url = `/InspectionGuidance/GetWorkerStatisticsInfoApi?StreetNo=${this.$route.query.StreetNo}`
    //   // http://111.160.78.62:9942/GarbagePointsApi/InspectionGuidance/GetWorkerStatisticsInfoApi?StreetNo=2
    //   var url = 'Vehicle/GetVehicleCurrentInfo?ClientNo=' + localStorage.getItem('CLIENT_NO')
    //   const { data } = await this.$Http.get(url)
    //   this.statisticalData = data
    //   eventBus.$emit('isCover', this.Visible)
    // },
    // 关闭实时在线统计
    // close () {
    //   this.Visible = false
    //   eventBus.$emit('isCover', this.Visible)
    // },
    // 右键表格某一行
    rowHandle (row, column, event) {
      window.event.returnValue = false
      this.row = row
      this.MouseEvent.left = event.clientX
      this.MouseEvent.top = event.clientY - 26 * 2

      this.MouseEvent.isShow = true
      // this.teamNumber = row.CLIENT_NO
    },
    // // 显示班组区域
    // groupArea (CLIENT_NO) {
    //   eventBus.$emit('showGroupArea', CLIENT_NO)
    //   this.MouseEvent.isShow = false
    // },
    // // 显示清扫队区域
    // clearArea (CLIENT_NO) {
    //   eventBus.$emit('showClearArea', CLIENT_NO)
    //   this.MouseEvent.isShow = false
    // },
    // // 清除区域
    // cleanArea () {
    //   eventBus.$emit('clearArea')
    //   this.MouseEvent.isShow = false
    // },
    // 导出Excel
    exportExcel () {
      let excelName = ''
      if (!document.querySelector('.group li.selected span')) {
        excelName = '维保人员实时信息列表'
      } else {
        excelName = document.querySelector('.group li.selected span').innerText + '-人员信息'
      }
      const tHeader = ['编号', '姓名', '电话', '类型', '在线状态', '最终定位时间', '分组', '负责维保公厕', '正在维保公厕', '经度', '纬度']
      const filterVal = ['VID', 'NAME', 'PHONE', 'WORKTYPE', 'STATUSstr', 'GPSTIME', 'CLIENT_NAME', 'FORWORK', 'INWORK', 'LNG', 'LAT']
      export2Excel(tHeader, filterVal, this.screeningData, excelName)
    },
    // 点击表格某一行
    clickRow (row) {
      this.MouseEvent.isShow = false
      this.clickRowData = row
    },
    // 双击表格某一行
    dblClickRow (row) {
      eventBus.$emit('mapDBrowToiletWorker', row)
    },
    // 双击表格某一行
    dblClickRowMonitor (row) {
      eventBus.$emit('warningItem', row)
    },
    // 右键导出Excel
    exportRowExcel () {
      this.MouseEvent.isShow = false
      const excelName = this.row.CLIENT_NAME + '-' + this.row.LICENSEPLATE + '-信息'
      const tHeader = ['编号', '车辆名称', '分组', '称重时间', '吨数', '垃圾类型', '来源类型', '工作点位', '处理场名称', '车辆类型', '最终定位时间', '位置', '航向', '航速', '经度', '纬度']
      const filterVal = ['VID', 'LICENSEPLATE', 'CLIENT_NAME', 'WEIGHING_TIME', 'TONNANG', 'RUBBISHTYPE', 'POINTTYPE', 'WORKINGPOINT', 'FACTORY', 'CAR_TYPE', 'ORIENTATION_TIME', 'POSITION', 'Direction', 'SPEED', 'LONGITUDE', 'LATITUDE']
      let ary = []
      ary.push(this.row)
      export2Excel(tHeader, filterVal, ary, excelName)
    },
    // // 开始跟踪
    // startTracking () {
    //   if (!this.clickRowData) {
    //     this.$message({
    //       message: '请先选择一位人员！',
    //       type: 'warning'
    //     })
    //     return false
    //   }
    //   this.clickRowData.isShow = true
    //   this.disabled1 = true
    //   this.disabled2 = false
    //   eventBus.$emit('Tracking', this.clickRowData)
    //   let timeId = null
    //   timeId = setInterval(() => {
    //     this.screenData()
    //     eventBus.$emit('Tracking', this.clickRowData)
    //     // console.log(11)
    //     if (this.trackingValue) clearInterval(timeId)
    //   }, 6000)
    // },
    // // 取消跟踪
    // cancelTracking () {
    //   this.trackingValue = true
    //   this.disabled1 = false
    //   this.disabled2 = true
    // },
    // 鼠标进入单元格显示其内容
    cellMouseEnter (row, column, cell, event) {
      cell.setAttribute('title', cell.innerText)
    },
    // 轨迹回放
    trajectory () {
      this.MouseEvent.isShow = false
      // 进入轨迹回放页面
      this.$router.push({ path: '/workerPlayback', query: { VID: this.row.VID } })
    },
    //
    showCCTV () {
      this.dialogVisibleCCTV = true
      this.dialogVisibleCCTVTitle = this.row.LICENSEPLATE
      var url = 'http://111.160.78.62:88/808gps/open/player/video.html?lang=zh&vehiIdno=' + this.row.LICENSEPLATE + '&account=bhclc&password=bhclc'
      document.getElementById('dialogVisibleCCTViframe').src = url
      // window.open(url)
      this.MouseEvent.isShow = false
      // this.MouseEvent.isShow = false
      // // 进入轨迹回放页面
      // this.$router.push({ path: '/playback', query: { VID: this.row.VID } })
    },
    // // 获取处理厂
    // async getPlacePointCLCApi () {
    //   var url = 'Vehicle/getPlaceCLC?CLIENTNO='+localStorage.getItem('CLIENT_NO')
    //   let { data } = await this.$Http.get(url)
    //   eventBus.$emit('mapPlacePointCLC', data)
    // },
    // // 获取中转站
    // async getPlacePointZZZApi () {
    //   var url = 'Vehicle/getPlaceZZZ?CLIENTNO='+localStorage.getItem('CLIENT_NO')
    //   let { data } = await this.$Http.get(url)
    //   eventBus.$emit('mapPlacePointZZZ', data)
    // },
    // // 获取农村点
    // async getPlacePointNCDApi () {
    //   var url = 'Vehicle/getPlaceNCD?CLIENTNO='+localStorage.getItem('CLIENT_NO')
    //   let { data } = await this.$Http.get(url)
    //   eventBus.$emit('mapPlacePointNCD', data)
    // },
    // // 获取餐饮单位
    // async getPlacePointCYApi () {
    //   var url = 'Vehicle/getPlaceNCD?CLIENTNO='+localStorage.getItem('CLIENT_NO')
    //   let { data } = await this.$Http.get(url)
    //   eventBus.$emit('mapPlacePointCY', data)
    // },
    // // 获取小区垃圾点
    // async getPlacePointXQCYApi () {
    //   var url = 'Vehicle/getPlaceNCD?CLIENTNO='+localStorage.getItem('CLIENT_NO')
    //   let { data } = await this.$Http.get(url)
    //   eventBus.$emit('mapPlacePointXQCY', data)
    // },
    // 获取处理厂边界点
    async getCLCPolygon () {
      var url = 'Vehicle/GetFactoryInfo?TYPE=1&ID=1001'
      let { data } = await this.$Http.get(url)
      eventBus.$emit('mapCLCPolygon', data)
    }
  },
  beforeDestroy () {
    clearInterval(this.timeID)
  }
}
</script>

<style scoped lang="less">
.monitoring {
  .el-form-item__content {
    max-width: 100px;
  }
  height: 100%;
  // position: relative;
  .el-form {
    width: 100%;
    height: 40px;
    line-height: 40px;
    // display: flex;
    // align-items: center;
    overflow: hidden;
    // border-bottom: 2px solid #007ACC;
    .el-form-item {
      // float: left;
      display: inline-block;
      margin: 0;
      // flex-shrink: 0;
      .el-input {
        height: 22px;
      }
    }
    .el-button {
      padding: 0 5px;
      height: 28px;
      border-radius: 2px;
      display: inline-block;
      /deep/span {
        font-size: 14px;
        // margin-left: 4px;
        line-height: 22px;
      }
    }
    .people_number {
      height: 40px;
      line-height: 40px;
      padding: 0 5px;
      color: #333;
      // float: left;
      display: inline-block;
      // flex-shrink: 0;
      span {
        display: inline-block;
        padding: 0 2px;
        height: 30px;
        border-bottom: 1px solid #ccc;
        box-sizing: border-box;
        text-align: center;
      }
    }
    .switch {
      display: inline-block;
      min-width: 100px;
      // height: 40px;
      // line-height: 40px;
      margin-left: 10px;
      // float: left;
      // flex-shrink: 0;
      span {
        margin-right: 2px;
        cursor: default;
        color: #606266;
      }
      .el-select {
        max-width: 100px;
        height: 22px;
        margin-left: 5px;
        /deep/.el-input__suffix {
          top: 8px;
          line-height: 24px;
        }
      }
    }
    .el-button {
      flex-shrink: 0;
    }
  }
  @media screen and (min-width: 1600px) {
    .fold_btn {
      opacity: 0;
    }
  }
  @media screen and (max-width: 1660px) {
    .el-form {
      width: 100%;
    }
    .fold_btn {
      display: inline-block;
    }
  }
  // @media screen and (min-width: 1455px) {

  // }
  @media screen and (max-width: 1455px) {
    .iconone {
      display: none !important;
    }
  }
  .fold_btn {
    position: relative;
  }
  .fold_btns {
    position: absolute;
    top: 65px;
    right: 0;
    width: auto;
    height: auto;
    overflow-y: scroll;
    background: #fff;
    z-index: 1111111;
    display: none;
  }
  .buttons {
    z-index: 55555;
    width: 80px;
    height: 120px;
    background: #eee;
  }
  .table_list {
    // position: absolute;
    // top: 70px;
    // bottom: 0px;
    margin-left: 20px;
    overflow-y: auto;
    width: calc(~'100% - 40px');

    height: calc(~'100% - 110px');
    .el-table {
      height: 100%;
    }
    /deep/.el-table__body-wrapper {
      height: calc(~'100% - 34px');
      overflow-y: auto;
    }
  }
}
// .icon-kaishi .icon-kaishi:hover{
//   background: #60a53e!important;
//   color: #eee;
// }
// .icon-tingzhi .icon-tingzhi:hover{
//   background: #cc8c8c!important;
//   color: #eee;
// }
.row_box {
  width: 120px;
  // height: 130px;
  color: #666;
  background-color: #f3f3f3;
  border: 1px solid #ccc;
  position: fixed;
  span {
    display: block;
    text-align: center;
    line-height: 26px;
    cursor: default;
    &:hover {
      color: #fff;
      background-color: #409eff;
    }
  }
}
// .row_box {
//   width: 120px;
//   // height: 130px;
//   color: #666;
//   background-color: #f3f3f3;
//   border: 1px solid #ccc;
//   position: fixed;
//   span {
//     display: block;
//     text-align: center;
//     line-height: 26px;
//     cursor: default;
//     &:hover {
//       color: #fff;
//       background-color: #007ACC;
//     }
//   }
// }
.statistical {
  width: 600px;
  min-height: 390px;
  position: fixed;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  z-index: 100;
  background-color: #fff;
  border-radius: 5px;
  overflow: hidden;
  .title {
    height: 40px;
    display: flex;
    align-items: center;
    border-bottom: 2px solid #ccc;
    padding-left: 5px;
    box-sizing: border-box;
    h3 {
      color: #666;
    }
    span {
      margin-left: 450px;
    }
  }
  .statistical_content {
    max-height: 350px;
    min-height: 310px;
    padding: 0 20px;
    background-color: #f3f3f3;
    overflow-y: auto;
  }
  .statistical_time {
    height: 40px;
    line-height: 40px;
    padding-left: 20px;
    color: #666;
    background-color: #f3f3f3;
    border-top: 1px solid #ccc;
    box-sizing: border-box;
  }
}
</style>
